#include <stdlib.h>
#include <time.h>
#define SDL_JEU_SELECTED
//#define NCU_JEU_SELECTED

#ifdef NCU_JEU_SELECTED
    #include "NCU_Jeu.h"
#endif

#ifdef SDL_JEU_SELECTED
    #include "SDL_menu.h"
#endif

int main(int argc, char *argv[])
{
    #ifdef NCU_JEU_SELECTED
    NCU_Jeu * J;
    J = malloc(sizeof(NCU_Jeu));
    srand(time(NULL));
    NCU_Boucle(J);
    free(J);
    #endif
    #ifdef SDL_JEU_SELECTED
    SDL_Surface *Ecran = NULL;
    SDL_Rect** modes=NULL;
    int x,y,flags=SDL_HWSURFACE|SDL_DOUBLEBUF;

    srand(time(NULL));
    SDL_Init(SDL_INIT_VIDEO|SDL_INIT_JOYSTICK);
    getResvideo(&x,&y,&flags);
    Ecran=SDL_SetVideoMode(x,y,32,flags);
    if (!Ecran)
    {
        modes=SDL_ListModes(NULL, SDL_FULLSCREEN|SDL_HWSURFACE);
        Ecran=SDL_SetVideoMode(modes[0]->w,modes[0]->h,32,flags);
    }
    SDL_WM_SetCaption("Une retraite en enfer", NULL);
    //SDL_WM_SetIcon(SDL_LoadBMP("sdl_icone.bmp"), NULL);
    SDL_Menu(Ecran);

    SDL_Quit();
    #endif
    return 0;
}
